package pl.krgr.vm2.ui.actions;

import org.springframework.beans.factory.annotation.Autowired;

import pl.vm.service.SeazonService;

import com.opensymphony.xwork2.ActionSupport;

public class AddSeazonAction extends ActionSupport {

	private static final long serialVersionUID = 1L;
	
	private String seazonName;
	
	@Autowired
	private SeazonService seazonService;
	
	public String execute() throws Exception {
		seazonService.createNewSeazon(seazonName);
		return SUCCESS;
	}

	public String getSeazonName() {
		return seazonName;
	}

	public void setSeazonName(String seazonName) {
		this.seazonName = seazonName;
	}
}
